package com.fauks.gmall.user.controller;

import com.alibaba.dubbo.config.annotation.Reference;
import com.fauks.gmall.bean.UmsMember;
import com.fauks.gmall.service.UserService;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
public class UserController {
    @Reference
    private UserService memberService;

    @RequestMapping("index")
    public String index() {
        return "hello world";
    }

    @RequestMapping("getAllUser")
    public List<UmsMember> getAllUser() {
        return memberService.getAllMember();
    }
}
